The present invention relates to a coding device and a coding method for performing coding by optimizing coding parameters in facsimile communication, etc.
In the prior art, when JBIG (Joint Bi-level Image Coding Experts Group) coding is performed in facsimile communication, etc., predetermined values set by specifications of devices or empirically acquired values are used as coding parameters set as coding conditions. The compression efficiency (coded data amount) of JBIG varies depending on combinations of the various coding parameters in accordance with characteristics of image data. However, since the conventional coding uses the predetermined parameter conditions, it fails to achieve optimal coding efficiency.
Although there is a prior-art technique wherein coding efficiency is optimized by varying an AT (Adaptive Template) pixel position, which is one of parameters, the effect of this technique is not adequate.
In general terms, in the conventional facsimile system, etc., when plural image data units are coded (or decoded) by one coding section with the same or different coding schemes, the image data units are assigned to plural task processes and are coded in a time-division manner. In this case, a firm for controlling the coding process successively carries out the plural task processes (coding processes) in units of a fixed (predetermined) time. However, in order to efficiently use the process unit time, it is necessary to start the coding after setting in the coding section an estimated number of lines which can be coded in the predetermined time.
In the prior art, however, it is not possible to exactly estimate the number of lines. Thus, only the number of lines, which is less than a maximum number and is processible without fail in the predetermined time, has to be set irrespective of the content of image data. Accordingly, there arise such problems that no coding is performed in some time period within the predetermined time and as a result the task process cannot efficiently be carried out in the predetermined unit time.
An object of the present invention is to provide a coding device and a coding method for performing coding by optimizing a coding efficiency in accordance with image data.
Another object of the invention is to provide a coding device capable of efficiently performing task processes in units of a predetermined time in accordance with image data.
In order to achieve the objects, the present invention provides a coding device having a coder for coding image data, the coding device comprising: a first setting section for setting therein a predetermined amount of image data to be coded; a storage section for storing a plurality of parameters; a generating section for generating a combination of parameters using the parameters stored in the storage section; an estimation section for estimating a coding amount by setting the combination of parameters generated by the generating section in the coder and coding the predetermined amount of image data set by the first setting section; a second setting section for setting in the coder the combination of parameters, which provides a minimum coding amount, on the basis of an estimation result obtained by the estimation section; and a control section for coding all the image data to be coded, when the second setting section has set in the coder the combination of parameters, which provides the minimum coding amount.
The invention also provides a coding device having a coder for coding image data, the coding device comprising: a first setting section for setting therein a predetermined amount of image data to be coded; a storage section for storing, in an associated manner, a predetermined amount of image data having a predetermined number of kinds of characteristic images, and optimal parameter combination information for coding the predetermined amount of image data having the characteristic images; an estimation section for comparing the image data set in the first setting section with a characteristic image of each image data stored in the storage section, thereby determining the presence/absence of similar image data; a second setting section for reading out, when the estimation section has determined the presence of the similar image data that is similar in characteristic image, the parameter combination information corresponding to the similar image data from the storage section, and setting the parameter combination based on the parameter combination information in the coder; and a control section for executing a control to code all the image data to be coded, when the second setting section has set the parameter combination in the coder.
The present invention provides a coding device having a coder for coding image data, the coding device comprising: a first setting section for setting a unit time of a task process; a second setting section for setting a predetermined amount of image data to be coded; a storage section for storing a plurality of parameters; a generating section for generating a combination of parameters using the parameters stored in the storage section; an estimation section for estimating a coding size by setting the combination of parameters generated by the generating section in the coder and coding the predetermined amount of image data set by the second setting section; a first calculation section for calculating a compression ratio from a minimum coding size of the parameter combination estimated by the estimation section; a second calculation section for calculating, from the compression ratio calculated by the first calculation section, a processible amount of coding within the unit time of the task process set by the first setting section; and control means for executing a control to set a task process time for the image data to be coded, on the basis of the processible amount for coding within the unit time of the task process calculated by the second calculation section.
The invention provides a coding device having a coder for coding image data in a Huffman scheme, the coding device comprising: a first setting section for setting a unit time of a task process; a second setting section for setting a predetermined amount of image data to be coded; an estimation section for estimating a coding size by coding the predetermined amount of image data set by the second setting section; a first calculation section for calculating a compression ratio from the coding size estimated by the estimation section; a second calculation section for calculating, from the compression ratio calculated by the first calculation section, a processible amount of coding within the unit time of the task process set by the first setting section; and control means for executing a control to set a task process time for the image data to be coded, on the basis of the processible amount for coding within the unit time of the task process calculated by the second calculation section.
The present invention provides a coding method for a coding device having a coder for coding image data, the method comprising: setting a predetermined amount of image data to be coded; generating a combination of parameters using a plurality of stored parameters; estimating a coding amount by setting the generated combination of parameters in the coder and coding the predetermined amount of the set image data; setting in the coder the combination of parameters, which provides a minimum coding amount, on the basis of an estimation result; and coding all the image data to be coded.
This invention provides a coding method for a coding device having a coder for coding image data, the method comprising: setting a unit time of a task process; setting a predetermined amount of image data to be coded; generating a combination of parameters using a plurality of stored parameters; estimating a coding size by setting the generated combination of parameters in the coder and coding the predetermined amount of the set image data; calculating a compression ratio from an estimated minimum coding size of the parameter combination; calculating, from the calculated compression ratio, a processible amount of coding within the set unit time of the task process; and setting a task process time for the image data to be coded, on the basis of the calculated processible amount for coding within the unit time of the task process.